<template>
	<div class="BIWRAP">
		<v-top></v-top>
		<div class="content">
			<div class="left" :style="{'backgroundImage':'url('+this.$store.getters.theme[3]+')'}">
				<div class="bk-avatar">
					<img src="../assets/img/user.png" class="img-circle" alt="">
					<p> <i class="el-icon-upload"></i>
						&nbsp;&nbsp;admin
					</p>
				</div>
				<div class="divider2"></div>
				<el-col>
					<el-menu :unique-opened="true" class="el-menu-vertical-demo" router @open="handleOpen" @close="handleClose" @select="handleSelectLeft" :theme="$store.getters.theme[4]" :default-active='routerName'>
						<el-menu-item index="/resources/alarmUser"> <i class="iconfont">&#xe6b0;</i>
							告警用户配置
						</el-menu-item>
						<el-menu-item index="/resources/alarmGroup"> <i class="iconfont">&#xe73a;</i>
							告警组别配置
						</el-menu-item>
						<el-menu-item index="/resources/userGroup"> <i class="iconfont">&#xe6f1;</i>
							用户组别配置
						</el-menu-item>
						<el-menu-item index="/resources/alarmConfiguration"> <i class="iconfont">&#xe735;</i>
							告警配置管理
						</el-menu-item>
						<!-- <el-menu-item index="/resources/dailyReport"> <i class="iconfont">&#xe710;</i>
							每日报表配置
						</el-menu-item>
						<el-menu-item index="/resources/vipCombatGradeFactor"> <i class="iconfont">&#xe7b4;</i>
							vip战斗力等级系数配置
						</el-menu-item> -->
					</el-menu>
				</el-col>
			</div>
			<div class="right">
				<router-view></router-view>
			</div>
		</div>
	</div>
</template>
<script>
import top from '../components/top.vue'
	export default {
	  name: 'app',
	  data () {
	    return {
	      activeIndex: '1',
	      routerName:"/resources/"+"alarmUser",//默认菜单
	    }
	  },
	  methods: {
	    handleSelectLeft(key, keyPath) {
	      console.log(key, keyPath);
	    },
	    handleOpen(key, keyPath) {
	      console.log(key, keyPath);
	    },
	    handleClose(key, keyPath) {
	      console.log(key, keyPath);
	    }
	  },
	  components: {
	  	"v-top": top
	  },
	  created(){
	    /*默认菜单改变*/
	    this.routerName = this.$route.path
	  }
	}
</script>
<style></style>